const jwt = require('express-jwt')
const { PRIVATE_KEY } = require('../utils/constant')

module.exports = jwt({
  secret: PRIVATE_KEY,
  credentialsRequired: true
}).unless({
  path: [
    '/',
    '/user/login',
    '/book/list',
      "/resume/createResume",
      "/resume/updateResume",
    "/resume/deleteResume",
    "/resume/uploadResume",
      "/resume/ResumeList",
    "/news/createNews",
    "/news/updateNews",
    "/news/deleteNews",
    "/news/uploadNews",
    "/news/NewsList",
      "/news/NewsCategoryList",
      "news//getOneNews",
      "news/NewsListCategory",
      "/enroll/EnrollList",
      "/enroll/uploadEnroll",
      "/user/createUser",
      "/user/getOneUserName",
      "/user/getOneUserPassword",
      "/user/updatePasswordUser1",
      "/user/sendEmail"
  ]
})
